package com.springboot.ww.platform.pd.dto;

import cn.hutool.core.util.ObjectUtil;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * @author ZH500
 * @date : 2020/11/18 19:34
 */
//@Document(indexName = "ww_test_#{forecastConfiguration.profile}", shards = 3, replicas = 2)
@Data
public class Record implements Serializable {

    /**
     * 请求报文
     */
    private String req;


    /**
     * 响应报文
     */
    private String resp;

    public void setCommonReq(String req) {
        if (ObjectUtil.isEmpty(this.req)) {
            this.req = req;
        } else {
            this.req = this.req + "|\n" + req;
        }
    }
    public void setCommonResp(String resp) {
        if (ObjectUtil.isEmpty(this.resp)) {
            this.resp = resp;
        } else {
            this.resp = this.resp + "|\n" + resp;
        }
    }
}
